package com.shiro.exception;


import lombok.Data;

@Data
public  class   MyException {
    //代表访问 什么路径导致 报异常
    //获取异常信息
    private  Integer code;
    private  String msg;
    private  String url;



    public static MyException error(){
        MyException exception = new MyException();
        exception.code=MyExceptionCode.ERROR;
        return exception;
    }

    public MyException setCode(Integer code){
         this.code=code;
         return this;
    }
    public MyException setMsg(String msg){
        this.msg=msg;
        return this;
    }
    public MyException setUrl(String url){
        this.url=url;
        return this;
    }
}

